from socket_server.HttpService import Service


class Index(Service):
    def doGet(self, request, response):
        response.write("<h1>首页</h1>")
        response.submit()

    def doPost(self, request, response):
        data = request.getFormData()
        res = data.get("lamp")
        response.write("<h1>POST请求</h1>")
        response.submit()
